package day003.homewordk;

public class Practice003 {
    public static void main(String[] args) {
        int count = 0;
        for (int i = 1; i <= 100; i++) {
            if (i % 2 == 0 && i % 3 == 0 && i % 5 == 0) {
                count++;
            }
        }
        System.out.println("100以内能被2、3、5整除的数有：" + count + "个");

        count = 0;
        int i = 1;
        while (i <= 100) {
            if (i % 2 == 0 && i % 3 == 0 && i % 5 == 0) {
                count++;
            }
            i++;
        }
        System.out.println("100以内能被2、3、5整除的数有：" + count + "个");
    }
}
